/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package poo.biblioteca;

import java.util.prefs.Preferences;
import poo.biblioteca.controladores.CtrPrincipal;

/**
 *
 * @author apo
 */
public class Biblioteca {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {

        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Windows".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(Biblioteca.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(Biblioteca.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(Biblioteca.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(Biblioteca.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }

        new CtrPrincipal(Preferences.userNodeForPackage(Biblioteca.class));


//        try {
//            DBManager dbm = new DBManager("jdbc:mysql://localhost:3306/biblioteca?"
//                    + "user=root&password=mysqlroot");
//            Connection con = dbm.getConnection();
//            java.sql.Statement stm = con.createStatement();
//            stm.executeQuery("select * from pais");
//        } catch (Exception ex) {
//            Logger.getLogger(Biblioteca.class.getName()).log(Level.SEVERE, null, ex);
//        }

    }
}
